package ru.amse.tsyganov.jumleditor.commands;

import ru.amse.tsyganov.jumleditor.model.ActivityGraph;
import ru.amse.tsyganov.jumleditor.model.State;
import ru.amse.tsyganov.jumleditor.view.ActivityGraphView;
import ru.amse.tsyganov.jumleditor.view.StateView;

public class CommandFactory {
	public static Command createMoveCommand(StateView<? extends State> stateView,
			int moveToX, int moveToY) {
		
		return new MoveStateCommand(stateView, moveToX, moveToY);
	}
	
	public static Command createNewStateCommand(
			ActivityGraphView<? extends ActivityGraph> activityGraphView,
			StateView<? extends State> stateView) {
		
		return new NewStateCommand(activityGraphView, stateView);
	}
	
	public static Command createNewTransitionCommand(
			StateView<? extends State> sourceStateView,
			StateView<? extends State> targetStateView) {
		
		return new NewTransitionCommand(sourceStateView, targetStateView);
	}
}
